﻿package com.jfdesgagne.utils.event {
	import flash.events.Event;
	
	public class DataEvent extends Event {
		public var data:Object;
		
		public function DataEvent($type:String, $data:Object, $bubbles:Boolean = false, $cancelable:Boolean = false) {
			super($type, $bubbles, $cancelable);
			this.data = $data;
		}
		
		public override function clone():Event {
			return new DataEvent(type, this.data, bubbles, cancelable);
		}
		
        public override function toString():String {
			 return formatToString("DataEvent", "params", "type", "bubbles", "cancelable");
		}
	}
}